﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using QConnectSDK;

namespace OpenConnect.WebSample.Photo
{
    public partial class PhotoList : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            var qzone2 = Session["QzoneOauth"] as QOpenClient;
            if (qzone2 != null)
            {

                var photolist = qzone2.GetCurrentUserListAlbum();

                this.dataGrid.DataSource = photolist.Album;
                this.dataGrid.DataBind();
                this.Literal1.Text = string.Format("相册总数{0}个", photolist.Albumnum);
            }
        }
    }
}